import { Entity, Column, Unique, Index, EntityRepository } from 'typeorm'
import { BaseEntity } from '../global'

@Entity('company')
@Unique(['companyid'])
export class CompanyEntity extends BaseEntity {
    @Column({ length: 32, comment: 'snowflake id' })
    companyid: string

    @Column({ length: 256, comment: '简称' })
    companyName: string

    @Column({ length: 256, comment: '公司全称' })
    companyFullName: string

    @Column({ length: 512, comment: '域名' })
    companyUrl: string

    @Column('int', { comment: '企业类型，0自属1伙伴2客户' })
    companyType: number

    @Column('int', { default: 1, comment: '状态，0停用1启用' })
    companyStatus: number
}
